import QtQuick
import QtQuick.Controls
import Qt5Compat.GraphicalEffects

ApplicationWindow {
    title: "GaussianBlur"
    visible: true
    width: 800
    height: 600

    Image {
        id: bg
        source: "qrc:/view.jpg"
        sourceSize: Qt.size(parent.width, parent.height)
        anchors.fill: parent
    }

    GaussianBlur {
        anchors.fill: bg
        source: bg
        radius: 8
        samples: 16
    }

    // 前景内容
    Rectangle {
        width: 300
        height: 200
        anchors.centerIn: parent
        color: "#60ffffff" // 半透明白色
        radius: 10

        Text {
            anchors.centerIn: parent
            text: "GaussianBlur"
            font.pixelSize: 24
            color: "#333333"
        }
    }
}
